<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
	<meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
	<title>Document</title>
	<style type="text/css">
		div{
			padding: 10px 20px 30px;
		}
	</style>
</head>
<body>
	<div></div>

	<script type="text/javascript">
		// if(window.getComputedStyle){
		// 	alert("我会getComputedStyle");
		// }else{
		// 	alert("我不会getComputedStyle，那四个啥？")
		// }

		var oDiv = document.getElementsByTagName("div")[0];

		if(window.getComputedStyle){
			alert(getComputedStyle(oDiv)["padding-left"]);
		}else{
			alert(oDiv.currentStyle.paddingLeft);
		}
	</script>
</body>
</html>